<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>首页</title>
    <script src="/file/js/cookies.js"></script>
</head>
<body>
    <h3>欢迎回来：<span id="spUsername">昵称</span></h3>
    <script>
        if(getCookie("logined")){
            spUsername.innerText = getCookie("username")
        }else{
            window.location.assign("/file/pages/login.html")
        }
    </script>
</body>
</html>